package com.lyx.question.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.lyx.question.dto.PaperWitnQuestionDto;
import com.lyx.question.dto.QuestionAnswerDto;
import com.lyx.question.dto.RankDto;
import com.lyx.question.entity.Paper;
import com.lyx.question.entity.QuestionRecord;
import org.springframework.stereotype.Service;

import javax.servlet.http.HttpServletRequest;
import java.time.LocalDate;
import java.util.List;
import java.util.Map;

/**
 * @author 14667
 * @date 2022/7/26 9:46
 */
@Service
public interface QuestionRecordService extends IService<QuestionRecord> {
    List<Paper> indexQuestionRecord(HttpServletRequest request);

    Map<String, List<Paper>> allQuestionRecord(HttpServletRequest request);

    List<RankDto> questionRecordRank();

    void updateQuestionRecord(PaperWitnQuestionDto paperWitnQuestionDto, HttpServletRequest request);

    PaperWitnQuestionDto getCurrentPaperQuestion(Integer paperId, HttpServletRequest request);

    QuestionAnswerDto comfirmAnswerQuestion(HttpServletRequest userId, Integer questionId, String userAnswer);

}
